<div class="sidebar" data-color="rose" data-background-color="black"
     data-image="{{ asset('material') }}/img/sidebar-1.jpg">
    {{--
      Tip 1: You can change the color of the sidebar using: data-color="purple | azure | green | orange | danger"

      Tip 2: you can also add an image using data-image tag
  --}}
    <div class="logo">
        <a href="{{route('dash')}}" class="simple-text logo-mini">
            BR2P
        </a>
    </div>
    <div class="sidebar-wrapper">
        <div class="user">
            <div class="photo">
                <img src="{{ auth()->user()->profilePicture() }}"/>
            </div>
            <div class="user-info">
                <a data-toggle="collapse" href="#collapseExample" class="username">
          <span>
            {{ auth()->user()->name }}
            <b class="caret"></b>
          </span>
                </a>
                <div class="collapse" id="collapseExample">
                    <ul class="nav">

                        <li class="nav-item">
                            <a class="nav-link" href="#">
                                <span class="sidebar-mini"> S </span>
                                <span class="sidebar-normal"> Settings </span>
                            </a>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
        <ul class="nav">
            <li class="nav-item{{ $activePage == 'dashboard' ? ' active' : '' }}">
                <a class="nav-link" href="{{ route('dash') }}">
                    <i class="material-icons">dashboard</i>
                    <p>{{ __('Dashboard') }}</p>
                </a>
            </li>
        @can('tutorial-list')
            <!-- START TUTORIAL -->
                <li class="nav-item {{ $menuParent == 'tutorial' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#tutorial" {{ $menuParent == 'tutorial' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">subject</i>
                        <p> Tutorial
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'tutorial' ? ' show' : '' }}" id="tutorial">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.tutorial')}}">
                                    <span class="sidebar-mini"> L </span>
                                    <span class="sidebar-normal"> Listar </span>
                                </a>
                            </li>

                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.tutorial.create')}}">
                                    <span class="sidebar-mini"> C </span>
                                    <span class="sidebar-normal"> Criar </span>
                                </a>
                            </li>
                        </ul>
                    </div>

                </li>
                <!-- END TUTORIAL -->
        @endcan
        @can('blog-list')
            <!-- START blog -->
                <li class="nav-item {{ $menuParent == 'blog' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#blog" {{ $menuParent == 'blog' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">subject</i>
                        <p> Blog
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'blog' ? ' show' : '' }}" id="blog">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.blog')}}">
                                    <span class="sidebar-mini"> L </span>
                                    <span class="sidebar-normal"> Listar </span>
                                </a>
                            </li>

                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.blog.create')}}">
                                    <span class="sidebar-mini"> C </span>
                                    <span class="sidebar-normal"> Criar </span>
                                </a>
                            </li>
                        </ul>
                    </div>

                </li>
                <!-- END blog -->
        @endcan
        @can('endereco-list')
            <!-- START ENDERECO -->
                <li class="nav-item {{ $menuParent == 'endereco' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#endereco" {{ $menuParent == 'endereco' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">book</i>
                        <p> Endereços
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'endereco' ? ' show' : '' }}" id="endereco">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.endereco')}}">
                                    <span class="sidebar-mini"> L </span>
                                    <span class="sidebar-normal"> Listar </span>
                                </a>
                            </li>

                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.endereco.create')}}">
                                    <span class="sidebar-mini"> C </span>
                                    <span class="sidebar-normal"> Criar </span>
                                </a>
                            </li>
                        </ul>
                    </div>

                </li>
                <!-- END ENDERECO -->
        @endcan
        @can('download-list')
            <!-- START DOWNLOAD -->
                <li class="nav-item {{ $menuParent == 'download' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#download" {{ $menuParent == 'download' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">get_app</i>
                        <p> Download
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'download' ? ' show' : '' }}" id="download">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.download')}}">
                                    <span class="sidebar-mini"> L </span>
                                    <span class="sidebar-normal"> Listar </span>
                                </a>
                            </li>

                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.download.create')}}">
                                    <span class="sidebar-mini"> E </span>
                                    <span class="sidebar-normal"> Enviar </span>
                                </a>
                            </li>
                        </ul>
                    </div>

                </li>
                <!-- END DOWNLOAD -->
        @endcan
        @can('termo-list')
            <!-- START TERMO -->
                <li class="nav-item {{ $menuParent == 'termo' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#termo" {{ $menuParent == 'termo' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">check_circle_outline</i>
                        <p> Termos
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'termo' ? ' show' : '' }}" id="termo">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.termo')}}">
                                    <span class="sidebar-mini"> L </span>
                                    <span class="sidebar-normal"> Listar </span>
                                </a>
                            </li>

                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.termo.create')}}">
                                    <span class="sidebar-mini"> C </span>
                                    <span class="sidebar-normal"> Criar </span>
                                </a>
                            </li>
                        </ul>
                    </div>

                </li>
                <!-- END TERMO -->
        @endcan
        @can('contato-list')
            <!-- START CONTATO -->
                <li class="nav-item {{ $menuParent == 'contato' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#contato" {{ $menuParent == 'contato' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">contacts</i>
                        <p> Contato
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'contato' ? ' show' : '' }}" id="contato">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.contato')}}">
                                    <span class="sidebar-mini"> L </span>
                                    <span class="sidebar-normal"> Listar </span>
                                </a>
                            </li>

                            {{-- <li class="nav-item">
                                 <a class="nav-link" href="{{route('dash.termo.create')}}">
                                     <span class="sidebar-mini"> C </span>
                                     <span class="sidebar-normal"> Criar </span>
                                 </a>
                             </li> --}}
                        </ul>
                    </div>

                </li>
                <!-- END CONTATO -->
        @endcan
        @can('associado-list')
            <!-- START associado -->
                <li class="nav-item {{ $menuParent == 'associado' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#associado" {{ $menuParent == 'associado' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">import_contacts</i>
                        <p> Associado
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'associado' ? ' show' : '' }}" id="associado">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.associado')}}">
                                    <span class="sidebar-mini"> L </span>
                                    <span class="sidebar-normal"> Listar </span>
                                </a>
                            </li>

                           <li class="nav-item">
                                 <a class="nav-link" href="{{route('dash.associado.create')}}">
                                     <span class="sidebar-mini"> A </span>
                                     <span class="sidebar-normal"> Adicionar </span>
                                 </a>
                             </li>
                        </ul>
                    </div>

                </li>
                <!-- END associado -->
        @endcan
        @can('role-list')
            <!-- START ACL -->
                <li class="nav-item {{ $menuParent == 'acl' ? 'active' : '' }}">
                    <a class="nav-link" data-toggle="collapse"
                       href="#acl" {{ $menuParent == 'acl' ? 'aria-expanded="true"' : '' }}>
                        <i class="material-icons">admin_panel_settings</i>
                        <p> ACL
                            <b class="caret"></b>
                        </p>
                    </a>

                    <div class="collapse{{ $menuParent == 'acl' ? ' show' : '' }}" id="acl">
                        <ul class="nav">
                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.users.index')}}">
                                    <span class="sidebar-mini"> U </span>
                                    <span class="sidebar-normal"> Usuários </span>
                                </a>
                            </li>

                            <li class="nav-item">
                                <a class="nav-link" href="{{route('dash.roles.index')}}">
                                    <span class="sidebar-mini"> P </span>
                                    <span class="sidebar-normal"> Permissões </span>
                                </a>
                            </li>
                        </ul>
                    </div>

                </li>
                <!-- END ACL -->
            @endcan
        </ul>
    </div>
</div>
